CC = gcc
CFLAGS = -Wall -Wextra -g
TARGETS = mytee mksparse mycp filelock scatter_gather append_reseek

all: $(TARGETS)

mytee: mytee.c
	$(CC) $(CFLAGS) -o $@ $<

mksparse: mksparse.c
	$(CC) $(CFLAGS) -o $@ $<

mycp: mycp.c
	$(CC) $(CFLAGS) -o $@ $<

filelock: filelock.c
	$(CC) $(CFLAGS) -o $@ $<

scatter_gather: scatter_gather.c
	$(CC) $(CFLAGS) -o $@ $<

append_reseek: append_reseek.c
	$(CC) $(CFLAGS) -o $@ $<

clean:
	rm -f $(TARGETS)

.PHONY: all clean 